package licode.unisop.client.vo;

import lombok.Getter;

@Getter
public class SopUserType {
    public static final SopUserType SYSTEM = new SopUserType("system");
    public static final SopUserType NORMAL = new SopUserType("normal");

    private final String userType;

    private SopUserType(String type) {
        userType = type;
    }

    public static SopUserType build(String type) {
        if (SYSTEM.userType.equals(type)) {
            return SYSTEM;
        } else {
            return NORMAL;
        }
    }

    public boolean isSystemUser() {
        return SYSTEM.userType.equals(userType);
    }

}
